
<div class="content-box">
    <div class="box-header clear">
        <ul class="tabs clear">
            <li ><a href='<?php echo base_url(); ?>provider/add' class="selected"><?php echo lang('btn_add') ?></a></li>
        </ul>
        <h2><?php echo lang('pg_provider') ?></h2>
    </div>
    <div class="box-body clear">
        <div id="data-table">
            <?php echo form_open(base_url() . 'provider/search'); ?>
            <div class="form-field clear">
                <label class="form-label fl-space2"><?php echo lang('lbl_provider_name') ?> :</label>
                <input type="input" value="<?php echo set_value('provider_name'); ?>" name="provider_name" id="provider_name" class="text" />
            </div>
            <table class="datatable">
                <thead>
                    <tr>
                        <th><?php echo lang('lbl_provider_name') ?></th>
                        <th><?php echo lang('lbl_address') ?></th>
                        <th><?php echo lang('lbl_address_house_number') ?></th>
                        <th><?php echo lang('lbl_address_postcode') ?></th>
                        <th><?php echo lang('lbl_status') ?></th>
                        <th></th>
                    </tr>
                </thead>
                <tbody>
                    <?php
                    foreach ($providers as $key => $item):
                        ?>
                        <tr id="row<?php echo $key; ?>">
                            <td><?php echo $item->provider_name; ?></td>
                            <td><?php echo $item->address; ?></td>
                            <td><?php echo $item->address_house_number; ?></td>
                            <td><?php echo $item->address_postcode; ?></td>
                            <td><?php echo $status[$item->status]; ?></td>
                            <td>
                                <a href="<?php echo base_url(); ?>provider/edit/<?php echo $item->id; ?>">
                                    <img title="<?php echo lang('btn_edit') ?>" alt="" class="icon16 fl-space2" src="<?php echo base_url() . SKINSPATH; ?>admin/images/ico_edit_16.png">
                                </a>
                                <a href="javascript:remove('row<?php echo $key; ?>','<?php echo base_url(); ?>provider/delete','<?php echo $item->id; ?>')">
                                    <img title="<?php echo lang('btn_delete') ?>" alt="" class="icon16 fl-space2" src="<?php echo base_url() . SKINSPATH; ?>admin/images/ico_delete_16.png">
                                </a>
                            </td>
                        </tr>

                    <?php endforeach; ?>
                </tbody>
            </table>
            <?php echo form_close(); ?>
        </div>
    </div>
</div>
<script type="text/javascript">
    InitTables(2);
</script>